import { request } from ".";

import type { RESPONSE } from "../types/base";
import type { Issue, IssueForm, Pager } from "./type/issueType";

export const reqAddIssue = (issue:IssueForm) => request.post<any,RESPONSE>("/api/issue",issue)
export const reqGetIssueByPage = (pager:Pager)=>request.get<any,RESPONSE<{total:number,list:Issue[]}>>("/api/issue",{
    params:pager
})
export const reqGetIssueById = (id:string)=> request.get<any,RESPONSE<Issue>>(`/api/issue/${id}`);